package com.xuni.neo4j.relation;

import com.xuni.neo4j.base.BaseRelation;
import com.xuni.neo4j.entity.Movie;
import com.xuni.neo4j.entity.Person;
import lombok.Data;
import org.springframework.data.neo4j.core.schema.GeneratedValue;
import org.springframework.data.neo4j.core.schema.Id;
import org.springframework.data.neo4j.core.schema.RelationshipProperties;
import org.springframework.data.neo4j.core.schema.TargetNode;

import java.util.List;

@Data
@RelationshipProperties
public class Relation extends BaseRelation {

    @Id
    @GeneratedValue
    private Long id;

    private List<String> roles;

    @TargetNode
    private Person person;
}